/**
 * 
 */
package com.gragra.clustering;
import java.io.IOException;
import com.gragra.data.MixingCorpus;
import com.gragra.sampling.ThreadedUniformAccess;
import com.gragra.sampling.vector.VectorStructure;
/**
 * @author Christoph Teichmann
 * created Mar 24, 2013 8:05:56 PM
 * @version 0.1
 */
public interface ClusteringAlgorithm
{
	/**
	 * cluster the VectorStructures in the given corpus into the given number of clusters
	 * @param corpus
	 * @throws InterruptedException 
	 * @throws IOException 
	 */
	void cluster(MixingCorpus<? extends VectorStructure> corpus, ThreadedUniformAccess tua) throws IOException, InterruptedException;
	/**
	 * returns the cluster number assigned to the given structure
	 * @param vs the structure for which the cluster number is requested
	 * @param number the number of the structure in the corpus of vectors that was used as input
	 * @return
	 */
	int getBest(VectorStructure vs, int number);
}